﻿using System;
using System.Collections.Generic;
using System.Text;

namespace NVR.BLL
{
    internal class DataProvider
    {
        private static NVR.DALFactory.DALFactory instance = null;
        static DataProvider()
        {
            System.Reflection.Assembly dll = System.Reflection.Assembly.LoadFile(System.Web.HttpContext.Current.Server.MapPath("~/DataProviders/" + "NVR.DALSqlProvider.dll"));
            instance = dll.CreateInstance("NVR.DALSqlProvider.DALSqlFactory") as NVR.DALFactory.DALFactory;
        }

        private DataProvider()
        {
        }
        public static NVR.DALFactory.DALFactory DefaultProvider
        {
            get
            {
                return instance;
            }
        }
    }
}
